
char* myStrncpy() {
	int i = 0;
	for (i = 0; str[i] = '\0' && i < n; i++) {
		dest[i] = src[i];
	}
	if (i < n) {
		dest[i] = '\0';
	}
}

int main()
{
	char dest[100] = "abcd";
	char* str = "abc";
	char* ret = myStrncpy(dest, str, 5);
	printf("%s\n", ret);
	return 0;
}